package org.nulldevice.tankshot;

import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;

public class GameWindowListener extends WindowAdapter {

	Game game;

	public GameWindowListener(Game game) {
		this.game = game;
	}

	public void windowClosing(WindowEvent event) {
		// event.getWindow().setVisible(false);
		event.getWindow().dispose();
		game.exit();
		// System.exit(0);
	}
}
